﻿using System;
using System.Text;
using System.Collections.Generic;
using System.Linq;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using WordsGroup.Answer;
using WordsGroup.Question;
using CodeTestFramework;
namespace WordsGroup.Test
{
    [TestClass]
    //[Answer(Namespace = "WordsGroup.Answer", Participant = "Effie")]
    //[Answer(Namespace = "WordsGroup.Answer", Participant = "Edward")]
    //[Answer(Namespace = "WordsGroup.Answer", Participant = "Libby")]
    //[Answer(Namespace = "WordsGroup.Answer", Participant = "Sofia")]
    [Answer(Namespace = "WordsGroup.Answer", Participant = "Jimson")]
    //[Answer(Namespace = "WordsGroup.Answer", Participant = "Bob")]
    public partial class Basictest : UnitTestBase<IGroupWords>
    {

        [TestMethod]
        public void Scenario1()
        {
            Assert.AreEqual<int>(6, Instance.GetMaxGroupValue("this is a title"), "2 repeated substring exist 2 words ");
        }

        [TestMethod]
        public void Scenario2()
        {
            Assert.AreEqual<int>(11, Instance.GetMaxGroupValue(" bleed bleed, feed"), "multiple repeated substring exist multiple words ");
        }

        [TestMethod]
        public void Scenario3()
        {
            Assert.AreEqual<int>(19, Instance.GetMaxGroupValue("Their elimination from the competition was a great surprise"), "multiple repeated substring exist multiple words ");
        }
    }
}
